package utils

import (
	"bufio"
	"fmt"
	"os"
)

func ReadInput() int {
	var num int
	f := bufio.NewReader(os.Stdin)
	fmt.Println("请输入数字，回车继续，#结束")
	input, _ := f.ReadString('\n')
	if input == "#\n" {
		return 0
	}
	fmt.Sscan(input, &num)
	return num
}

func ReadInputString() string {
	var inputStr string
	f := bufio.NewReader(os.Stdin)
	input, _ := f.ReadString('\n')
	if input == "#\n" {
		return ""
	}
	fmt.Sscan(input, &inputStr)
	return inputStr

}
